function minSquare(maxLen, minLen) {
  const remainder = maxLen % minLen;
  if (remainder !== 0) {
    return minSquare(minLen, remainder)
  } else {
    return minLen;
  }
}

console.log(minSquare(120, 70))